/**
 * 字典类别模型 
 * 
*/
module.exports = (sequelize, Sequelize) => {
    return sequelize.define("sys_dict_type", {
        id: {
            type: Sequelize.INTEGER,
            notNull: true,
            primaryKey: true,
            comment: '字典类别主键',
            autoIncrement: true, // 自增整形主键
        },
        dictName: {
            type: Sequelize.STRING,
            notNull: true,
            notEmpty: true,
            comment: '字典名称',
            field:'dict_name'
        },
        dictType: {
            type: Sequelize.STRING,
            notNull: true,
            notEmpty: true,
            primaryKey: true,
            comment: '字典类型',
            field:'dict_type'
        },
        dictStatus: {
            type: Sequelize.STRING(2),
            notEmpty: true, // 不能为空
            comment: '状态 0:正常 1:停用',
            defaultValue: '0',
            field:'dict_status'
        },
        createId: {
            type: Sequelize.STRING,
            notEmpty: true,
            comment: '创建者',
            defaultValue:'admin',
            field:'create_id'
        },
        updateId: {
            type:  Sequelize.STRING,
            notEmpty: true,
            comment: '更新者',
            defaultValue:'admin',
            field:'update_id'
        },
        remark: {
            type:  Sequelize.STRING,
            comment: '备注',
        }
    })
}